-- GENERATED SPELL FOR [Kin'weelay] --


function spell0_2519(pUnit, Event) --@Create Soul Gem,Self--
pUnit:FullCastSpellOnTarget(3660,pUnit)
pUnit:RegisterEvent('Sorts_2519', 545, 1)
end

function spell1_2519(pUnit, Event) --@Speak with Heads,Self--
pUnit:FullCastSpellOnTarget(3644,pUnit)
pUnit:RegisterEvent('Sorts_2519', 5000, 1)
end

function Sorts_2519(pUnit, Event)
local choix_sorts_2519 = math.random(0, 1)
if choix_sorts_2519 == 0 then
pUnit:RegisterEvent('spell0_2519', 1, 1)
end
if choix_sorts_2519 == 1 then
pUnit:RegisterEvent('spell1_2519', 1, 1)
end
end

function mob2519_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_2519', math.random(1500, 3000), 1)
end

function mob2519_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob2519_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob2519_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(2519, 1, 'mob2519_Action')
RegisterUnitEvent(2519, 2, 'mob2519_Leave')
RegisterUnitEvent(2519, 3, 'mob2519_Kill')
RegisterUnitEvent(2519, 4, 'mob2519_Die')
